<?php
/**
* 装箱工作
*/

class Action
{

    /**
     * 提交订单
     */
    public function index()
    {

        $id = an_request('id', 0);
        $status = Request::getParam('status', 1);

        if (!$id) {
            return '访问链接有误，请确认重试';
        }

        $order_info = order_helper::get_order_info($id);
        if (!$order_info) {
            return '访问的订单不存在';
        }

        $order_relation_list = order_helper::get_order_relation_by_order_id($id);

        // 杯型信息
        $cup_list_info = cup_helper::get_order_cup_data($id);

//        var_dump(TCPDFBarcode::getBarcodePNG);

        Response::assign('status', $status);
        Response::assign('order_id', $id);
        Response::assign('cup_list_info', $cup_list_info);
        Response::assign('order_info', $order_info);
        Response::assign('order_relation_list', $order_relation_list);
        Response::display('admin/packing.html');
    }
}